<?php 
include TMPL_PATH.'public/header.phtml';
?>
<div class="subnav">
    <div class="content-menu ib-a blue line-x" style="overflow:hidden;">
    	<div style="float:left;margin-right:50px;">
        <a href='javascript:;' class="on"><em>充值和提现申请</em></a><span>|</span>
        <a href='<?php echo U('user/account_add', 'uid='.$user['id']);?>' ><em>添加申请</em></a>
      </div>
    	<div style="color:#000;">
    	<form name="searchform" action="__SELF__"  method="post">
    		<select name="process_type">
        <option value="-1">类型</option>
        <option value="0">充值</option>
        <option value="1">提现</option>
      </select>&nbsp;&nbsp;
    		<select name="is_paid">
        <option value="-1">到款状态</option>
        <option value="0">未确认</option>
        <option value="1">已完成</option>
        <option value="2">取消</option>
      </select>&nbsp;&nbsp;
      会员名称：<input type="text" class="input-text" value="" name="user_name">
      充值号：<input type="text" class="input-text" value="" name="recharge_id">
				<input type="submit" value="搜索" class="button" name="search">
    		</form>
    	</div>
    </div>
</div>
<div class="pad_10">
<div class="table-list">
    <table width="100%" cellspacing="0" >
        <thead>
            <tr>
            <th align='left' width="100">充值号</th>
            <th align='left' width="100">会员名称</th>
            <th align='center' width="200">操作日期</th>
            <th align='center' width="100">类型</th>
            <th align='center' width="100">金额</th>
            <th align='center' width="100">支付方式</th>
            <th align='center' width="100">到款状态</th>
            <th align='center' width="100">操作员</th>
            <th>操作</th>
            </tr>
        </thead>
     <tbody>
   <?php
   	if(isset($accountList) && $accountList):
   		foreach ($accountList as $v):
   ?>
			<tr>
					<td align='left'><?php echo $v['process_type'] ? '':'recharge_'.$v['id'];?></td>
					<td align='left'><?php echo $v['username'];?></td>
					<td align='center'><?php echo date('Y-m-d H:i:s',$v['add_time']) .($v['paid_time'] ? ' - '.date('Y-m-d H:i:s',$v['paid_time']) : null);?></td>
					<td align='center'><?php echo $v['process_type'] ? '提现' : '充值';?></td>
					<td align='center'><?php echo $v['amount'];?></td>
					<td align='center'><?php echo $v['payment'];?></td>
					<td align='center'><?php echo $v['is_paid'] ? ($v['is_paid']==2 ? '取消' : '已完成') : '未确认' ;?></td>
					<td align='center'><?php echo $v['admin_user'];?></td>
					<td align='center'><a href='<?php echo U('user/account_edit', 'aid='.$v['id']);?>' >编辑</a></td>
				</tr>
	<?php
		endforeach;
		endif;
	?>
   </tbody>
    </table>
  <div id="pages"><?php echo $pageShow;?></div>
</div>
</div>
</body>
</html>